<template>
	<view v-html="info" class="main">
	</view>
</template>

<script>
	export default{
		data(){
			return{
				info:''
			}
		},
		onLoad(options) {
			this.getInfo(options.type)
			uni.setNavigationBarTitle({
				title: options.title
			})
		},
		methods:{
			getInfo(type) {
				this.$api.post('/getconfig', {
					attr:type
				}).then(res => {
					if (res.code == 1) {
						res.data = res.data.replace(/<img/g,
							"<img style='max-width:100%;height:auto'")
						this.info = res.data
					}
				}).catch((res) => {
				
				})
				
			}
		}
	}
</script>

<style scoped lang="scss">
	.main{
		padding: 20rpx;
	}
</style>